<script setup>

import {ref} from "vue";
import axios from "axios";
import TopMenu from "@/component/TopMenu.vue";

const personBean = ref({})
// localhost:8080/insert?name=zhangsan&age=18&sex=男&address=北京
//字符串  有规则地字符串  json
// {name:'xiaohong',age:18,sex:'女',address:'嘉兴',爱好:['study','sleep'],cc:{}}
const submit = () => {
  // 发送数据到后端服务
  axios.get('/server/insert', personBean.value)
      .then(res=>{
        console.log(res);
      })
}
</script>

<template>
  <div>
    <TopMenu></TopMenu>
  </div>
  <div class="container">
    <RouterView></RouterView>
  </div>
</template>

<style scoped>
  .container{
    width: 100%;
    height: 80vh;
    display: flex;
    justify-content: center;
    align-items: center;
  }
</style>
